package net.spacebeeshooter.gui;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import net.spacebeeshooter.items.Item;

public class AddListener implements ActionListener {
	
	private TabPanel tabPanel;
	private Item item;
	
	public AddListener(TabPanel tabPanel, Item item) {
		this.tabPanel = tabPanel;
		this.item = item;
	}
	
	@Override
	public void actionPerformed(ActionEvent arg0) {
		tabPanel.addTab(new EditorPanel(item));
	}

}
